﻿#define _CRT_SECURE_NO_WARNINGS 1

//编程初学者入门训练第一百题
//BC102 矩阵元素定位
//https://www.nowcoder.com/practice/b8e6a46992fe4e11b2822b20561b6d94?tpId=107&tqId=33383&rp=1&ru=/exam/oj/ta&qru=/exam/oj/ta&sourceUrl=%2Fexam%2Foj%2Fta%3FtpId%3D107&difficulty=undefined&judgeStatus=undefined&tags=&title=

#include <stdio.h>

int main() {
    int n = 0, m = 0;
    int row = 0, col = 0;
    scanf("%d %d", &n, &m);

    int arr[5][5];
    //输入数据
    for (int i = 0; i < n; i++) {
        for (int j = 0; j < m; j++) {
            scanf("%d", &arr[i][j]);
        }
    }
    //查找数据
    scanf("%d %d", &row, &col);
    printf("%d", arr[row - 1][col - 1]);

    return 0;
}